package com.lintf.web.controller.bot;

import com.lintf.bot.domain.dto.BotDailyLikeAddDTO;
import com.lintf.bot.domain.dto.BotDailyLikeListDTO;
import com.lintf.bot.service.IBotDailyLikeService;
import com.lintf.common.core.controller.BaseController;
import com.lintf.common.core.domain.AjaxResult;
import com.lintf.common.core.page.TableDataInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @ system:Mac
 * @ author:lin tingfeng
 * @ data:2024/1/18 17:09
 * @ package_name:com.lintf.web.controller.bot
 * @ project_name:mobile-project
 * @ desc:
 */
@RestController
@RequestMapping("/bot/daily/like")
public class BotDailyLikeController extends BaseController {

    @Autowired
    private IBotDailyLikeService botDailyLikeService;

    @PostMapping("/add")
    public AjaxResult add(@RequestBody BotDailyLikeAddDTO dto) {
        botDailyLikeService.add(dto);
        return AjaxResult.success();
    }

    @GetMapping("/list")
    public TableDataInfo get(BotDailyLikeListDTO dto){
        return getDataTable(botDailyLikeService.selectDailyLikeList(dto));
    }
}
